#include "testdocuments.h"
#include <Core>

TestDocuments::TestDocuments(QObject *parent) :
    QObject(parent)
{
}

void TestDocuments::initTestCase()
{
    Core::instance().init();
}

void TestDocuments::cleanupTestCase()
{
}

void TestDocuments::testAddDocument()
{
//    QPointer<DocumentContainer> docCont = Core::instance().documentContainer();
//    QVERIFY(docCont != 0);
//    QPointer<Document> doc1 = docCont->addDocument();
//    QVERIFY(doc1 != 0);
//    QVERIFY(docCont->activeDocument() == doc1);

//    QPointer<Document> doc2 = docCont->addDocument();
//    QVERIFY(doc2 != 0);
//    QVERIFY(docCont->activeDocument() == doc1);

//    docCont->setActiveDocument(doc2);
//    QVERIFY(docCont->activeDocument() == doc2);

//    DocumentList docs = docCont->documents();
//    QVERIFY(docs.count() == 2);

//    doc1->setTitle("Test Title 1");
}
